package com.example.alpho.controller;

import com.example.alpho.common.config.DemoConfig;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author fangyf18371
 * date：2018/7/27 12:15
 * description：demo
 */
@RestController
public class DemoController {
    @Autowired
    private DemoConfig config;

    @RequestMapping("/hello")
    public String index(){
        return "Hi,Spring Boot!";
    }

    @RequestMapping("/env")
    public Object getEnv(){
        return config;
    }
}
